package com.synergy.stockflow.production.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.synergy.stockflow.production.create.MaterialRequisitionVo;
import com.synergy.stockflow.production.entity.MaterialRequisition;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface MaterialRequisitionMapper extends BaseMapper<MaterialRequisition> {
    List<MaterialRequisitionVo> selectAll(Page<MaterialRequisitionVo> objectPage,
                                          @Param("requisitionCode") String requisitionCode,
                                          @Param("requisitionName") String requisitionName,
                                          @Param("requiredTime") String requiredTime,
                                          @Param("status") Integer status
    );

    MaterialRequisitionVo selectByCode(@Param("requisitionCode") String requisitionCode);

    int updateListStatus(String requisitionId);

}